repo: Add `auto_transaction` and `TransactionGuard`
authorColin Walters <walters@verbum.org>
Tue, 28 Sep 2021 19:37:26 +0000 (15:37 -0400)
committerColin Walters <walters@verbum.org>
Fri, 6 May 2022 16:53:57 +0000 (12:53 -0400)
commitf8852ca94569a15d2fd92cf6cc1e9e9948c1648a
tree40601d8e6621da81f1dac32f9487d6086508a16c
parent69950574f7157227fdded98fe2b297afac4f9783
repo: Add `auto_transaction` and `TransactionGuard`

This gives auto-cancelling semantics on `Drop`, plus a nicer
`.commit()` method on the transaction.

Matches the currently private `_OstreeRepoAutoTransaction` in the C
library.
rust-bindings/rust/src/repo.rs
rust-bindings/rust/tests/util/mod.rs